Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow index IsDescending to get empty array for all-descending #28489

Merged
merged 2 commits into from
Jul 26, 2022

Conversation

roji
Copy link
Member

@roji roji commented Jul 21, 2022

Improves #27210 by allowing aan empty list parameter to IsDescending, meaning that all index columns should be descending.
Also normalizes explicitly-set all-ascending/all-descending to null/empty array respectively.

(addresses API review, #27588)

@roji roji requested a review from AndriySvyryd July 21, 2022 16:47
@roji roji mentioned this pull request Jul 21, 2022
53 tasks
@roji roji linked an issue Jul 21, 2022 that may be closed by this pull request
@roji
Copy link
Member Author

roji commented Jul 21, 2022

Question: is it worth introducing AllDescending or similar on IndexAttribute? Right now to specify all-descending, you do this ugly thing:

[Index(..., IsDescending = new bool[0])]

@AndriySvyryd
Copy link
Member

I'd prefer adding AllDescending to giving special meaning to an empty array
@dotnet/efteam

@roji
Copy link
Member Author

roji commented Jul 26, 2022

@dotnet/efteam added AllDescending.

@roji roji merged commit 129bacc into dotnet:main Jul 26, 2022
@roji roji deleted the IndexDescending branch July 26, 2022 21:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support for index ordering (ASC/DESC)
2 participants